//用于做网络请求
const rp = require('request-promise');
exports.main = async (ctx, db) => {
    let param = ctx._req.event.param;
    return rp.get('https://api.ake999.com/api/dsp/32ECF5188388F9BC33BE926B6E18E758FCD709C48F03D454D3/202037144/?url=' + param.mediaUrl)
        .then(res => JSON.parse(res))
        .catch(err => {
            console.log(err);
            return {
                code: 500,
                msg: '魔法失灵啦'
            }
        });
}